fix(ember): Restore ember package contents#5318
Merged
Conversation
Contributor
size-limit report 📦
|
Lms24
approved these changes
Jun 27, 2022
Member
Lms24
left a comment
There was a problem hiding this comment.
LGTM. Given how different the ember package is from the rest, I think overriding the default .npmignore is definetily justified.
Just in case you didn't, let's make sure we inspect the created tarball contents before releasing the next patch.
| echo "COMMIT_MESSAGE=$(git log -n 1 --pretty=format:%s $COMMIT_SHA)" >> $GITHUB_ENV | ||
| outputs: | ||
| commit_label: "${{ env.COMMIT_SHA }}: ${{ env.COMMIT_MESSAGE }}" | ||
| commit_label: '${{ env.COMMIT_SHA }}: ${{ env.COMMIT_MESSAGE }}' |
Member
There was a problem hiding this comment.
No action required: I guess those are some automatic Prettier (or similar) changes?
Contributor
Author
There was a problem hiding this comment.
Yup, I'll leave it (I'm sorry for the messed up git history).
Contributor
Author
I generated all of the tarballs locally before and after the changes in this PR. Diffing the two files only reveals ember changes. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Problem Description
As reported in #5296, from version
7.1.1to7.2.0of the Ember SDK, a majority of the contents of the npm packages suddenly disappeared.We traced the issue back to a Node.js dependency change (in patch
v16.15.1) that bumped npm from version8.5.5to8.11.0. That npm version bump included a fix (npm/cli#4917 & npm/npm-packlist#102, first appeared in npmv8.11.0) that restores the functionality thatnpm packalso looks at workspace roots for.npmignorefiles. For the ember SDK package, we actually depended on the bug that is now fixed, as a result messing up our package contents.Changes
To fix the ember package contents we simply override the workspace root
.npmignorerules in the.npmignorefile of the ember package. Essentially, for the ember package, this now works as if there were no.npmignorefile in the workspace root.Additionally, as of this PR, we pin the default node version (and implicitly the npm version). So we have reproducible builds.
Fixes #5296